Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WIP: maintenance workflow documentation #262

Open
wants to merge 20 commits into
base: master
Choose a base branch
from

Conversation

Ocramius
Copy link
Member

@Ocramius Ocramius commented Oct 28, 2018

This is a stub of the release process that I was slowly putting into words.

As discussed with @carusogabriel and @Majkl578 while at PHP Central Europe, we need to get this automated, and removed from the documentation once that's done (as in: documentation just references the release tool)

TODO:

  • check how this actually renders
  • document code review as part of the maintenance workflow
  • document dependency upgrades as part of the maintenance workflow
  • document signed tags for releases

@Ocramius Ocramius added Build Related to the build process of the website itself Documentation Documentation related issues WIP Something that is a work in progress. labels Oct 28, 2018
SenseException and others added 2 commits October 28, 2018 23:38
Co-Authored-By: Ocramius <ocramius@gmail.com>
Co-Authored-By: Ocramius <ocramius@gmail.com>
@SenseException SenseException requested a review from jwage October 29, 2018 09:39
@Ocramius
Copy link
Member Author

@jwage can you please talk about this workflow with @doctrine/team-mongodb-odm? I think ORM and ODM are quite different right now, but if we build an automation, we should unify the workflows.

@SenseException I marked it as WIP because it is incomplete, but I don't remember what's missing. Can you check it again, please?

@alcaeus
Copy link
Member

alcaeus commented Oct 29, 2018

We'll discuss this at the next ODM hangout.

@malarzm
Copy link
Member

malarzm commented Oct 29, 2018

I think the biggest difference is that ODM's version description is usually linking to CHANGELOG.md which contains description of what changed (and we usually craft it manually). And I personally use github to tag a new release instead of console :)

@Ocramius
Copy link
Member Author

I think the biggest difference is that ODM's version description is usually linking to CHANGELOG.md

Good one! What do we do about CHANGELOG.md? I think we should start maintaining it, especially requiring an entry in it for every relevant patch. If we can ensure that, then the release notes (and therefore the git tag message) can be inferred from the latest block in CHANGELOG.md. Should I add it to the document?

And I personally use github to tag a new release instead of console :)

We need signed tags for our releases, especially with the size of our audience. This isn't feasible via Github UI...

@malarzm
Copy link
Member

malarzm commented Oct 29, 2018

So in ODM we always write an entry in CHANGELOG before tagging new release, they usually look like this - list there not always contains all PRs merged, because some are not worthy mentioning (i.e. docs). Sometimes we put more info to the changelog, that usually happens for a minor release (like this one).

Bugfix release notes follow this scheme (copy-paste-fix links):

Maintenance release.

Please see [changelog](https://github.com/doctrine/mongodb-odm/blob/1.2.x/CHANGELOG-1.2.md#125-2018-07-20) for a complete list of fixes.

All issues and pull requests in this release may be found under the [1.2.5 milestone](https://github.com/doctrine/mongodb-odm/issues?q=milestone%3A1.2.5).

We need signed tags for our releases, especially with the size of our audience. This isn't feasible via Github UI...

I can change my ways, no problem 👍

@Ocramius
Copy link
Member Author

I can change my ways, no problem +1

I don't want to impede your work, hence my strong focus on automation in this documentation. At some point, I'd like to remove humans from the release process in this organisation.

@malarzm
Copy link
Member

malarzm commented Oct 29, 2018

I can change my ways, no problem +1

I don't want to impede your work, hence my strong focus on automation in this documentation. At some point, I'd like to remove humans from the release process in this organisation.

That was about signing tags and not using github UI ;) FWIW I think maintaing changelog is better as it's easily grep-able.

Each of the following steps are documented for humans to perform them
manually, but maintainers and contributors are highly encouraged to try
and automate them away into tooling that is commonly available across
the organisation projects, as well as the community at large.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We also talked about automating PR merges, after passed builds and approvals (and i.e. no blocking label).
Ideally we should also guard automatic merges by Roave/BackwardCompatibilityCheck that would block auto-merge (ideally as a separate CI integration, not part of the Travis build directly).

Copy link
Member Author

@Ocramius Ocramius Oct 30, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, Roave BC is a bit too strict, but we can add our (laxer) rules to CI. Also, I need to make it faster before it is introduced.

------------------------------------------------

The primary role of a maintainer, besides being also a contributor,
is to sort incoming proposals by their category:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As part of this standardization, we SHOULD sync labels across all repositories and also their colors (at least all listed below). Currently it's random.

source/contribute/maintainer.rst Outdated Show resolved Hide resolved
or **MINOR** release (depending on team internal agreement).
Consumers should not rely on ``master`` unless they are prepared
to adapt their codebase at every potentially breaking change.
* ``MAJOR.MINOR.x`` - always to be considered the next planned
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Considering that we currently mostly use MAJOR.MINOR, what is the motivation to use MAJOR.MINOR.x?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ORM, DBAL and common started using MAJOR.MINOR with 2.2, while the rest either doesn't have enough branches for it to be called a model or are using MAJOR.MINOR.x.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fwiw either branch name format works with the website.

source/contribute/maintainer.rst Outdated Show resolved Hide resolved
source/contribute/maintainer.rst Outdated Show resolved Hide resolved

Then it is possible to tag a release.

Please note that tags *MUST* be signed. Unsigned releases will be
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Please note that tags *MUST* be signed. Unsigned releases will be
Please note that tags **MUST** be GPG-signed by either the maintainer's or Doctrine's GPG key.
Unsigned releases will be

As discussed, as part of automating releases. we may introduce a Doctrine GPG key that will be signed by all maintainers and internally used to create tags.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't like the anonymity of a shared GPG key - anyone could sign a malicious tag and hide between the shared identity. I'd advocate against that and suggest we keep signing with individual keys.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wouldn't be anonymous: it would require trust from the doctrine maintainers

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking at one tag, would I be able to tell which maintainer signed the tag?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, it would be done by tooling, not by a person

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Even if it's done by tooling, as long as it's triggered by a human (./bin/doctrine release a.b.c) it should be signed by that human. Otherwise, there's no significant advantage to signing with the GitHub key, except that we're maintaining our own key for the sake of it.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Key K is signed as trusted by maintainer A, B, C. Subkey K1 is deployed to a (safe) environment, where the automation takes over tagging and releasing when things are triggered. There won't be a ./bin/doctrine release a.b.c: the aim is to remove it, and completely automate releases as merges happen. Yes, that would be a lot of releases :)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think that's feasible at all at the current time, hence my opposition to this. Let's take things one at a time. If we ever get to the point where we want to do a release on every merge, we can bring this up again. Until that point, let's leave the original suggestion in: people sign tags with their GPG key instead of relying on GitHubs default key.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

instead of relying on GitHubs default key.

Yeah, this should never be done anyway 👍

Majkl578 and others added 3 commits October 30, 2018 10:28
Co-Authored-By: Ocramius <ocramius@gmail.com>
Co-Authored-By: Ocramius <ocramius@gmail.com>
Co-Authored-By: Ocramius <ocramius@gmail.com>
@SenseException
Copy link
Member

I think this should also work well for changes in the documentation.
@Ocramius Do we need to emphasize that changes in the documentation shouldn't be in the same commits as code changes? Also: New features should get a proper documentation before they can be merged.

@Ocramius
Copy link
Member Author

Ocramius commented Nov 4, 2018

shouldn't be in the same commits as code changes?

I don't mind if the commits overlap or not, but they should probably be in the same patch. I don't think it has to do with the maintenance workflow though: we can put it in issue/PR templates, maybe?

@@ -31,7 +39,7 @@ locally:

.. code-block:: console

$ git clone git@github.com:username/doctrine2.git doctrine2-orm
$ git clone git@github.com:<username>/doctrine2.git doctrine2-orm
Copy link
Member

@morozov morozov Jan 10, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This requires an update due to doctrine/orm#7552.

@@ -59,16 +67,167 @@ Optionally, add any additional contributor/maintainer forks, e.g.:

$ git remote add romanb git://github.com/romanb/doctrine2.git
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This could be reworded to <username> for consistency with the change in git clone ....

@carusogabriel
Copy link
Contributor

Gosh, I need to do some research about it, I forget :P

@Ocramius
Copy link
Member Author

Folks, I can't get to work on this further in the next weeks: is anybody in @doctrine/team-documentation willing to finish this up?

@jwage
Copy link
Member

jwage commented Feb 3, 2019

@Ocramius I can take the ball.

… maintainer workflow

Co-Authored-By: Ocramius <ocramius@gmail.com>
@Ocramius
Copy link
Member Author

Ocramius commented Feb 4, 2019

@jwage thanks!

Whilst it is possible to automate some of these decisions, humans
are still better at categorising these changes due to the amount of
nuances that are involved in the software development process.

Branching Model
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This section needs an update after the decision at the EUFOSSA hackathon. See https://github.com/doctrine/automatic-releases#todos for the process.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Build Related to the build process of the website itself Documentation Documentation related issues WIP Something that is a work in progress.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants